<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<meta http-equiv="cache-control" content="no-cache" />
		<meta http-equiv="expires" content="0" />
		<meta name="viewport"
			content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
		<meta name="apple-mobile-web-app-capable" content="yes" />
		<meta name="apple-mobile-web-app-status-bar-style" content="white" />
		<meta name="format-detection" content="telephone=no" />
		<meta http-equiv="x-rim-auto-match" content="none" />
		<title>拨云见日科技</title>
		<link rel="SHORTCUT ICON" href="/static/favicon.ico" type="image/x-icon"/>
		<script src='/static/js/jquery.js' type='text/javascript'></script>
		<script src='/static/js/qrcode.js' type='text/javascript'></script>
		<script src='/static/js/layui.js' type='text/javascript'></script>
		<link href="/static/css/index.css" rel="stylesheet" type="text/css" />
		<link href="/static/css/layui.css" rel="stylesheet" type="text/css" />
	</head>
	<body>
		{% include "base.html" %}
		<div class="wrapper">
			<div class="wrapper_cont">
				<dl class='product_list' style="width: 90%">
					<dd style="    font-size: 50px;text-align: center;">
						{{split(data,",")[1]}}
					</dd>
					{% include "right.html" %}
				</dl>
			</div>
		</div>
	</body>
	<script type='text/javascript'>
		var param = '{{split(data,",")[0]}}'
		$(function(){
			getValue();
		})

        function getValue(){
		    v = document.getElementById('v').value;
		    if(commFun(v,param)){
		    	return;
			}
		    var robot_id = '{{split(data,",")[0]}}';
			if(commFun(v,robot_id)){
				return;
			}
			if(v){
				if(v.indexOf("A")==-1){
					layer.msg("无效容器号")
				}else{
					var action = $("#mm").attr("action")
					var sql = "INSERT INTO byjr_requestpool(id,request_type,request_user,request_local,container_code,request_status,request_time)values(nextval('byjr_requestpool_id_seq'::regclass),'TPSJ','0','0','"+v+"','','now()')"
					$.post(action,{sql:sql},function(result){
						layer.msg('托盘上架请求发送成功');
						setTimeout(function(){
							location.href = "index.html?data="+robot_id
						},1000);
					});
				}
			}
			document.getElementById('v').value = "";
            setTimeout(getValue,1000);
        }
	</script>
	{% include "footer.html" %}
</html>
